Skip to content

feat: enable canister creation with subnet ID in the URL#9919

Merged
mraszyk merged 13 commits intomasterfrom
mraszyk/update-call-to-subnet-id
Apr 20, 2026
Merged

feat: enable canister creation with subnet ID in the URL#9919
mraszyk merged 13 commits intomasterfrom
mraszyk/update-call-to-subnet-id

Conversation

@mraszyk
Copy link
Copy Markdown
Contributor

@mraszyk mraszyk commented Apr 17, 2026

This PR adds a new public HTTP endpoint /api/v4/subnet/<effective_subnet_id>/call on the replica that supports call to the create_canister endpoint of the management canister (aaaaa-aa). It is specified in this PR.

@github-actions github-actions Bot added the feat label Apr 17, 2026
@mraszyk mraszyk changed the title feat: enable update call with subnet ID in the URL feat: enable canister creation with subnet ID in the URL Apr 17, 2026
@mraszyk mraszyk marked this pull request as ready for review April 17, 2026 09:58
@mraszyk mraszyk requested review from a team as code owners April 17, 2026 09:58
@mraszyk mraszyk requested a review from Copilot April 17, 2026 10:48
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR adds support for a new replica HTTP update-call endpoint that is addressed by subnet ID (/api/v4/subnet/<effective_subnet_id>/call) and is restricted to aaaaa-aa (ic:00) create_canister calls, aligning with the referenced public spec change.

Changes:

  • Introduces /api/v4/subnet/{effective_subnet_id}/call router/handler wiring in the public HTTP endpoints crate.
  • Extends ingress validation to distinguish between canister-scoped vs subnet-scoped “effective destination” and enforces subnet endpoint restrictions.
  • Adds/updates unit + system tests and a test-agent helper for exercising the new subnet endpoint; updates Bazel visibility/deps accordingly.

Reviewed changes

Copilot reviewed 11 out of 11 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
rs/http_endpoints/public/src/lib.rs Wires a new v4 subnet call router into the main axum router.
rs/http_endpoints/public/src/call/call_sync.rs Adds route + handler for /api/v4/subnet/.../call and refactors sync call handling to accept an “effective destination”.
rs/http_endpoints/public/src/call/call_async.rs Updates async call path to use the new “effective destination” validation API.
rs/http_endpoints/public/src/call.rs Adds EffectiveDestination and extends ingress validation to enforce subnet endpoint constraints.
rs/http_endpoints/test_agent/src/lib.rs Adds CallSubnet test client for the new endpoint.
rs/http_endpoints/public/tests/common/mod.rs Adds UpdateEndpoint to parameterize tests across canister vs subnet call endpoints.
rs/http_endpoints/public/tests/test.rs Expands test matrix to cover subnet v4 sync calls + adds focused subnet endpoint tests.
rs/http_endpoints/public/tests/load_shed_test.rs Extends load shedding tests to include the subnet v4 endpoint.
rs/tests/networking/http_endpoints_public_spec_test.rs Adds system/spec test exercising subnet v4 behavior on a real topology.
rs/http_endpoints/test_agent/BUILD.bazel Extends visibility to allow fuzz subpackages to depend on test_agent.
rs/http_endpoints/fuzz/BUILD.bazel Adds dependency on the test_agent crate.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread rs/http_endpoints/public/src/call/call_sync.rs Outdated
Comment thread rs/http_endpoints/public/src/call/call_sync.rs
Comment thread rs/http_endpoints/public/tests/test.rs
Comment thread rs/http_endpoints/public/src/call/call_sync.rs Outdated
@mraszyk mraszyk added this pull request to the merge queue Apr 20, 2026
Merged via the queue into master with commit 6ab9da3 Apr 20, 2026
37 checks passed
@mraszyk mraszyk deleted the mraszyk/update-call-to-subnet-id branch April 20, 2026 09:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants